<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>添加优惠券</title>
    <link rel="stylesheet" href="/layui/css/layui.css">
    <link rel="stylesheet" href="/css/coupon/coupon-add.css">
    <script src="/layui/layui.js"></script>
    <script src="/js/coupon/coupon-add.js"></script>
</head>
<body>
        <div class="layui-row" >
            <div class="layui-elem-quote">
                <span style="font-size: 18px">添加优惠券</span>
                <span style="float: right;">
                    <button class="layui-btn" id="shuaxin"><i class="layui-icon layui-icon-refresh"></i>刷新</button>
                    <button class="layui-btn" onclick="goBack()"><i class="layui-icon layui-icon-left"></i>返回</button>
                </span>
            </div>
        </div>
        <form class="layui-form" action="" style="width:800px;margin:40px auto">
            <div class="layui-form-item">
                <div class="layui-form-mid layui-word-aux">优惠券名称:</div>
                <div class="layui-input-block">
                    <input type="text" id="couponName" required lay-verify="required" autocomplete="off" class="layui-input" placeholder="请输入优惠券名称"/>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-form-mid layui-word-aux">优惠券金额:</div>
                <div class="layui-input-block">
                    <input type="text" id="couponPrice" required lay-verify="required" autocomplete="off" class="layui-input" placeholder="请输入优惠券金额"/>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-form-mid layui-word-aux">开始时间</div>
                <div class="layui-input-block">
                    <input type="text" name="startDate" required lay-verify="required" class="layui-input" id="startDate" placeholder="请选择开始时间"/>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-form-mid layui-word-aux">结束时间</div>
                <div class="layui-input-block">
                    <input type="text" name="endDate" required lay-verify="required" class="layui-input" id="endDate" placeholder="请选择结束时间">
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-form-mid layui-word-aux">上线/下线</div>
                <div class="layui-input-block">
                    <input type="radio" name="online" value="2" title="上线" checked>
                    <input type="radio" name="online" value="3" title="下线">
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-form-mid layui-word-aux">发放数量:</div>
                <div class="layui-input-block">
                    <input type="text" name="issueQuantity" id="issueQuantity" required  lay-verify="required" autocomplete="off" class="layui-input" placeholder="请输入发放数量">
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-form-mid layui-word-aux">发放方式:</div>
                <div class="layui-input-block">
                    <select name="grant" id="grant">
                        <option value="1">请选择优惠券获取方式</option>
                        <option value="2">自动发放</option>
                        <option value="3">活动领取</option>
                        <option value="4">人工发放</option>
                        <option value="5">无限制</option>
                    </select>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-form-mid layui-word-aux">优惠券类型</div>
                <div class="layui-input-block">
                    <select name="type" id="type">
                        <option value="1">请选择优惠券发放方式</option>
                        <option value="2">商品</option>
                        <option value="3">视频</option>
                    </select>
                </div>
            </div>
            <hr>
            <div id="box-body-dy">
                <button type="submit" class="layui-btn" id="submit" onclick="addCoupons()" style="margin:10px 0px 0px 45%;">添加优惠券</button>
            </div>
        </form>
</body>
</html>